home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Fatted Calf
/
The Fatted Calf.iso
/
Applications
/
Games
/
NeXTmj
/
Source
/
GameInterface.cc
< prev
next >
Wrap
Text File
|
1991-03-18
|
2KB
|
130 lines
/* Generated by Interface Builder */
#import "TileCountManager.h"
#import "GameCoordinator.h"
extern "Objective-C" {
#import "GameInterface.h"
}
extern "C" {
#import <assert.h>
}
@implementation GameInterface
- init {
[ super init ];
gameCoordinator = NULL;
tileCountManager = NULL;
return self;
}
- free {
delete gameCoordinator;
delete tileCountManager;
return [ super free ];
}
- appDidInit:sender {
assert( tileCountView );
assert( gameBoardView );
tileCountManager = new TileCountManager( tileCountView );
gameCoordinator = new GameCoordinator( gameBoardView, tileCountManager );
application_initialized = YES;
[ tileCountView display ];
[ gameBoardView display ];
return self;
}
- undoClick:sender {
(( GameCoordinator* )gameCoordinator )->undoClick();
return self;
}
- helpClick:sender {
(( GameCoordinator* )gameCoordinator )->helpClick();
return self;
}
- againClick:sender {
(( GameCoordinator* )gameCoordinator )->againClick();
return self;
}
- newClick:sender {
(( GameCoordinator* )gameCoordinator )->newClick();
return self;
}
- gameBoardDraw {
if( application_initialized )
(( GameCoordinator* )gameCoordinator )->drawImage();
return self;
}
- tileCountDraw {
if( application_initialized )
(( TileCountManager* )tileCountManager )->drawImage();
return self;
}
- click:( const NXPoint * )aPoint {
(( GameCoordinator* )gameCoordinator )->click( aPoint );
return self;
}
- doubleClick:( const NXPoint * )aPoint {
(( GameCoordinator* )gameCoordinator )->doubleClick( aPoint );
return self;
}
@end